$(function () {
    $.post("news/spfenlei",{"type":1},function (data) {
        console.log(data)
        $.each(data[0],function (index,news1) {
            // $(".menu_r").append(
            //     "<li><a href=\"javascript:;\">"+news1.name+"</a></a></li>"
            // )
            $("#ul").append(
                "<li  v-for=\"p1 in list\">\n" +
                "<div class=\"fj\">\n" +
                "<span class=\"n_img\"><span></span><img src=\"images/nav10.png\" /></span>\n" +
                "<span class=\"fl\">"+news1.name+"</span>\n" +
                "</div>\n" +
                "<div class=\"zj\" >\n" +
                "<div class=\"zj_l\">\n" +
                "</div>\n" +
                "<div class=\"zj_r\">\n" +
                "<a href=\"#\"><img src=\"images/n_img1.jpg\" width=\"236\" height=\"200\" /></a>\n" +
                "<a href=\"#\"><img src=\"images/n_img2.jpg\" width=\"236\" height=\"200\" /></a>\n" +
                "</div>\n" +
                "</div>\n"

            )
            $.each(data[1],function (index1,news2) {
                if (news2.parentid == news1.id){
                    $("#ul").find("li").eq(index).find(".zj_l").append(
                        "<div class=\"zj_l_c\"><h2>"+news2.name+"</h2></div>"
                    )
                    $.each(data[2],function(index2,news3){
                        var fl= escape("全部>"+news1.name+">"+news2.name+">"+news3.name)
                        var parentId2 = news2.id;
                        if(news2.id==news3.parentid){
                            $("#ul").find('li').eq(index).find(".zj_l_c")
                                .append("<a href=\"http://localhost:7777/sp.html?id="+news3.id+"\" class='threeFL' data-id=''>"+news3.name+"</a>|")
                        }

                    })
                }


            })
        })
        jq(".leftNav ul li").hover(
            function(){
                jq(this).find(".fj").addClass("nuw");
                jq(this).find(".zj").show();
            }
            ,
            function(){
                jq(this).find(".fj").removeClass("nuw");
                jq(this).find(".zj").hide();
            }
        )
        })



    $(".head").load("head.html")
    $(".top").load("gw.html")




})